/**
 * Created by ren on 01/04/2017.
 */
import React, {Component} from 'react';
import CheckOrder from '../views/CheckOrder'
import {Drawer} from 'native-base'
import Filter from '../views/Filter';

export default class NavigationDrawer extends Component {
  closeDrawer = () => {
    this.drawer._root.close()
  };

  render() {
    return (
      <Drawer
        ref={(ref) => { this.drawer = ref; }}
        side="right"
        openDrawerOffset={0.3} // 20% gap on the right side of drawer
        panCloseMask={0.2}
        closedDrawerOffset={-3}
        content={<Filter closeDrawer={()=>this.closeDrawer()}/>}
        onClose={()=>this.closeDrawer()}>
        <CheckOrder/>
      </Drawer>
    );
  }
}